GUIFile("CKEditorSetup.php")); # HTML page setup ?>

".$Msg."\n"; } ?>

"portal name (from System Configuration)", "ADMINEMAIL" => "administrator email address (from System Configuration)", "BASEURL" => "base URL for the site (useful in constructing links in the message)", "LEGALNOTICE" => "legal/copyright notice (from System Configuration)", "USERLOGIN" => "user account name (like ".User::getCurrentUser()->Get("UserName").")", "USERREALNAME" => "\"real\" name of user (as set in Preferences)", "USEREMAIL" => "email address of user", "RESOURCELIST" => "list of resources that triggered email", "RESOURCECOUNT" => "number of items in list of resources that triggered email", "DATE" => "full date (like ".date("M j Y").")", "TIME" => "full time (like ".date("g:ia T").")", "YEAR" => "year (like ".date("Y").")", "MONTH" => "month as a number (like ".date("n").")", "DAY" => "day as a number (like ".date("j").")", "MONTHNAME" => "month name (like ".date("F").")", "MONTHABBREV" => "month name abbreviation (like ".date("M").")", "WEEKDAYNAME" => "weekday name (like ".date("l").")", "DAYWITHSUFFIX" => "day as a number with suffix (like ".date("jS").")", ]; $ItemKeywords = [ "RESOURCENUMBER" => "numerical position of resource in list", "RESOURCEID" => "ID of resource (useful in constructing URLs)", "RESOURCEVIEWURL" => "URL for full record view for resource", "FIELD:xxx" => "field value (see below)", ]; if ($GLOBALS["G_PluginManager"]->PluginEnabled("SocialMedia")) { $ItemKeywords += [ "SHARE:FACEBOOK" => "URL to share the resource on Facebook", "SHARE:TWITTER" => "URL to share the resource on Twitter", "SHARE:LINKEDIN" => "URL to share the resource on LinkedIn" ]; } $SavedSearchKeywords = [ "SEARCHNAME" => "user-defined name of saved search", "SEARCHCRITERIA" => "text description of search criteria", ]; function DisplayKeywordList($Keywords) { ?>

$Description) { ?>
X--X

# Adding New Template

# Editing Message Template

These keywords will be replaced when the email is sent as follows:

The following keywords only apply to saved search mailings:

The following keywords only apply in the List Item text:

For the "X-FIELD:xxx-X" keyword, the "xxx" portion should correspond to a field name with all spaces and non-alphanumeric characters removed and all letters translated to upper case (e.g.X-FIELD:DATESUBMITTED-X).

Basic Settings
Template Name |
Send One Email per Matching Resource | />
From |
Subject |
HTML Message Settings
Body | <?PHP print htmlspecialchars($H_Body, ENT_SUBSTITUTE); ?> Note: Do not include `<!DOCTYPE...>`, `<html>`, `<head>`, or `<body>` tags.
List Item | <?PHP print htmlspecialchars($H_ItemBody, ENT_SUBSTITUTE); ?>
Collapse Margins | /> Yes /> No
Plain Text Message Settings
Body | <?PHP print htmlspecialchars($H_PlainTextBody, ENT_SUBSTITUTE); ?> Note: The plain text message is only displayed to users who are unable to view HTML e-mail or have configured their e-mail application to display plain text instead of HTML in e-mail.
List Item | <?PHP print htmlspecialchars($H_PlainTextItemBody, ENT_SUBSTITUTE); ?>
Additional Settings
Extra Message Headers | <?PHP print htmlspecialchars($H_Headers); ?>

Test Resource IDs: Test Seed:
$Template) { $H_Templates[$Id]["TemplateUsers"] = $H_Plugin->FindTemplateUsers($Id); $H_Templates[$Id]["Name"] = "".$Template["Name"].""; } $ListFields = [ "Name" => [ "AllowHTML" => true, ], "Users" => [ "Heading" => "", "ValueFunction" => function ($Item, $FieldName) { if (count($Item["TemplateUsers"])) { return "Currently in use and cannot be deleted.
" ."Used by: ".implode(", ", $Item["TemplateUsers"]).""; } else { return ""; } }, ], ]; $ItemList = new ItemListUI($ListFields); $ItemList->Heading("Email Message Templates"); $ItemList->ItemsPerPage(count($H_Templates)); $ItemList->BaseLink(""); $ItemList->fieldsSortableByDefault(false); $ItemList->AddActionButton( "Edit", "index.php?P=P_Mailer_EditMessageTemplates&AC=Edit&ID=\$ID", "pencil.png" ); $ItemList->AddActionButton( "Delete", "index.php?P=P_Mailer_EditMessageTemplates&AC=Delete&ID=\$ID", "cross.png", function ($Item) { return count($Item["TemplateUsers"]) == 0 ? true : false ; } ); $ItemList->Display($H_Templates); ?>

# Confirm Template Deletion

Template Name |
From |
Subject |
Body |
List Item |
Plain Text Body |
Plain Text List Item |
Extra Message Headers |